Skip to content

fix(scheduler): fail after summarized action errors - #899

Open
seonghobae wants to merge 2 commits into
mainfrom
fix/scheduler-action-error-exit-current-main-20260809
Open

fix(scheduler): fail after summarized action errors#899
seonghobae wants to merge 2 commits into
mainfrom
fix/scheduler-action-error-exit-current-main-20260809

Conversation

@seonghobae

Copy link
Copy Markdown
Contributor

Summary

  • return a non-zero scheduler process result only after the full bounded PR scan and structured summary when any decision is action_error
  • preserve successful exit semantics for ordinary policy waits, blocks, skips, and deferred capacity
  • make the organization sweep distinguish a pre-summary repository access denial from a summarized per-PR mutation failure, so both targeted and sweep paths expose the same terminal truth
  • document the policy and add workflow/CLI regression contracts

RCA and feasibility

The symptom was a green workflow containing an action_error. The immediate cause was main() unconditionally returning 0; the root cause was that per-PR isolation and process-level execution truth were conflated. The sweep had a second classification boundary: it matched generic 403 text even inside a valid structured action-error payload.

The smallest feasible repair is to compute the exit result from completed decisions after print_summary() and use the existing versioned payload as proof that a sweep failure occurred after repository materialization. Raising immediately was rejected because it would starve later PRs and lose the bounded-scan contract; weakening or removing the unavailable-repository exception was rejected because legitimately unenrolled repositories remain externally non-actionable.

Validation

  • python scripts/ci/pr_review_merge_scheduler.py --self-test
  • deterministic direct probes: one error followed by an unaffected PR, multiple errors, and no-error success
  • python -m compileall -q for production and changed tests
  • git diff --check
  • exact-head CI and security evidence required before merge

Fixes #894

@coderabbitai

coderabbitai Bot commented Aug 9, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@seonghobae, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 58 minutes

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 5fd52bdc-e19e-4b40-b6fd-035936bb3c2f

📥 Commits

Reviewing files that changed from the base of the PR and between 6eb06cd and 323835b.

📒 Files selected for processing (6)
  • .github/workflows/pr-review-merge-scheduler.yml
  • CHANGELOG.md
  • docs/doctoring/pr-review-merge-scheduler.md
  • scripts/ci/pr_review_merge_scheduler.py
  • tests/test_pr_review_merge_scheduler.py
  • tests/test_required_workflow_queue_contract.py

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@seonghobae
seonghobae enabled auto-merge (squash) August 9, 2026 13:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Reliability] Propagate scheduler mutation failures to a non-passing workflow result

1 participant